<template>
    <button @click="sendToParent">Send Message to Parent</button>
</template>
  
<script setup>
import { defineEmits } from 'vue';

const emit = defineEmits(['updateMessage']);

function sendToParent() {
    emit('updateMessage', 'Hello from Child');
}
</script>